let FDUI = {}

// 已从码表获取-废弃
FDUI.templateTypes = [{
  code: '1101',
  name: '仅表格'
}, {
  code: '1102',
  name: '自定义页面'
}, {
  code: '1110',
  name: '左树右空'
}, {
  code: '1111',
  name: '左树右表'
}, {
  code: '1120',
  name: '标签表格'
}, {
  code: '1130',
  name: '简单报表'
}, {
  code: '1140',
  name: '表单页面'
}, {
  code: '1150',
  name: '待办已办'
}]

FDUI.pageTypes = [{
  code: 1,
  name: '一级页面'
}, {
  code: 2,
  name: '二级页面'
}, {
  code: 3,
  name: '公共页面（不授权）'
}, {
  code: 4,
  name: '页面分组'
}]

FDUI.yesNo = [{
  code: 0,
  name: '否'
}, {
  code: 1,
  name: '是'
}]

FDUI.eleType = {
  Text: '1',
  Date: '2',
  Check: '3',
  Int: '4',
  Numberic: '5',
  CodeData: '6',
  LookUp: '7',
  File: '8',
  Image: '9',
  Service: '10'
}

FDUI.visible = [{
  code: 0,
  name: '不可见'
}, {
  code: 2,
  name: '只读'
}, {
  code: 3,
  name: '新增可写，修改只读'
}, {
  code: 4,
  name: '修改'
}]

FDUI.eleTypeDic = [{
  code: '0',
  name: '表主键',
  children: []
}, {
  code: '1',
  name: '文本框',
  children: [{
    code: '10',
    name: '普通文本'
  }, {
    code: '11',
    name: '手机号输入'
  }, {
    code: '12',
    name: '身份证号'
  }, {
    code: '13',
    name: '银行卡'
  }, {
    code: '14',
    name: '配置数据源'
  }]
}, {
  code: '2',
  name: '日期',
  children: [{
    code: '20',
    name: '日期'
  },
  {
    code: '21',
    name: '日期+时间'
  }]
}, {
  code: '3',
  name: '复选框',
  children: [{
    code: '30',
    name: '默认是否'
  }]
}, {
  code: '4',
  name: '整数',
  children: [{
    code: '40',
    name: '默认数字'
  }]
}, {
  code: '5',
  name: '小数',
  children: [{
    code: '50',
    name: '默认'
  }]
}, {
  code: '6',
  name: '码表',
  children: [{
    code: '60',
    name: '单级下拉框'
  }, {
    code: '61',
    name: '多级下拉框'
  }, {
    code: '62',
    name: '单选框'
  }]
}, {
  code: '7',
  name: '关联字段',
  children: [{
    code: '70',
    name: '通用下拉'
  }, {
    code: '71',
    name: '通用弹窗'
  }]
}, {
  code: '8',
  name: '附件',
  children: [{
    code: '80',
    name: '普通附件'
  }]
}, {
  code: '9',
  name: '图片',
  children: [{
    code: '90',
    name: '图片'
  }]
}, {
  code: '10',
  name: '系统服务',
  children: [{
    code: '101',
    name: '默认'
  }, {
    code: '102',
    name: '穿梭框'
  }]
}]

FDUI.eleDisType = {
  'text': {
    default: 'ele-distype-10',
    tel: 'ele-distype-11',
    idcard: 'ele-distype-12',
    bankcard: 'ele-distype-13'
  },
  'date': {
    default: 'ele-distype-20',
    datetime: 'ele-distype-21'
  },
  'check': {
    default: 'ele-distype-30',
    required: 'ele-distype-31'
  },
  'int': {
    default: 'ele-distype-40',
    year: 'ele-distype-41',
    yearmonth: 'ele-distype-42'
  },
  'numberic': {
    default: 'ele-distype-50'
  },
  'codeData': {
    default: 'ele-distype-60',
    multiple: 'ele-distype-61'
  },
  'lookup': {
    default: 'ele-distype-70',
    dialog: 'ele-distype-71'
  },
  'file': {
    default: 'ele-distype-80'
  },
  'image': {
    default: 'ele-distype-90'
  },
  'service': {
    default: 'ele-distype-101'
  }
}

window.FDUI = FDUI
